package com.vshining.cryptoki.jna.pkcs11t;

import com.sun.jna.NativeLong;
import com.sun.jna.Pointer;
import com.sun.jna.Structure;

import java.util.Arrays;
import java.util.List;

/**
 * @author Shining Wang <shiningwang@vshining.com>
 */
@SuppressWarnings("unused")
public class CK_PKCS5_PBKD2_PARAMS extends Structure {
    NativeLong saltSource;
    Pointer pSaltSourceData;
    NativeLong ulSaltSourceDataLen;
    NativeLong iterations;
    NativeLong prf;
    Pointer pPrfData;
    NativeLong ulPrfDataLen;
    Pointer pPassword;
    NativeLong ulPasswordLen;

    @Override
    protected List getFieldOrder() {
        return Arrays.asList(
                "saltSource",
                "pSaltSourceData",
                "ulSaltSourceDataLen",
                "iterations",
                "prf",
                "pPrfData",
                "ulPrfDataLen",
                "pPassword",
                "ulPasswordLen"
        );
    }
}
